/**
 * 
 */
package HostLibra;

import java.rmi.Naming;

/**
 * @author Diego2
 *
 */
public class ServidorRemoto {
	public ServidorRemoto() {
		//Rodando o rmi
		try{
			java.rmi.registry.LocateRegistry.createRegistry(1099);
			System.out.println("Rmi Rodando");
		}catch(Exception e){
			System.out.println("Erro no rmi Registry");
			e.printStackTrace();
		}
		try {
			IConversaoLibra servico = new ConversaoLibraImpl();
			Naming.rebind("ConversorLibra", servico);
		} catch (Exception e) {

			e.printStackTrace();
		}
	}
	

}
